<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>JS demo</title>
  </head>
  <body>
    <p>九九乘法表:</p>
    <div class="test"></div>
    <script type="text/javascript">
      var i,j;
      var cha ="";
      for(i=1;i<10;i++){
        for(j=1;j<i+1;j++){
          cha = cha+ String(i)+"*"+String(j)+"="+String(i * j)+"&nbsp;&nbsp;";
        }
        document.write(cha+"<br>");
        cha ="";
      }
    </script>
<br><br>
<p>Console.log</p>
<script type="text/javascript">
  var i,j;
  var cha ="";
  for(i=9;i>0;i--){
    for(j=9;j>i-1;j--){
      cha = cha+ String(i)+"*"+String(j)+"="+String(i * j)+"\t";
    }
console.log(cha);    cha ="";
  }
</script>

  </body>
</html>
